package com.ljx.itbbs.server.mall.domain.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;

@Data
@TableName("tb_order")
public class OrderEntity {

    @TableId(value = "id")
    @ApiModelProperty("订单ID")
    private Long id;

    @ApiModelProperty("用户ID")
    @TableField("user_id")
    private Long userId;

    @ApiModelProperty("商品ID")
    @TableField("obj_id")
    private String objId;

    @ApiModelProperty("花费金额")
    @TableField("money")
    private Integer money;

    @ApiModelProperty("商品类型")
    @TableField("type")
    private Integer type;

    @ApiModelProperty("描述")
    @TableField("`desc`")
    private String desc;

    @ApiModelProperty("数量")
    @TableField("number")
    private Integer number;

    @ApiModelProperty("支付状态")
    @TableField("payment_status")
    private Integer paymentStatus;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @ApiModelProperty("创建时间")
    @TableField("create_time")
    private Date createTime;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @ApiModelProperty("修改时间")
    @TableField("update_time")
    private Date updateTime;

    @ApiModelProperty("状态（1：正常，2：禁用）")
    @TableField("status")
    private Integer status;

}
